import request from "../../api/request";
const market = "market";

// 获取表单
export function initAllAccInfo(data) {
  return request({
    url: market + "/indAccInfoAction/initAllAccInfo",
    method: "post",
    data: data || {}
  });
}

// 新增
export function save(data) {
  return request({
    url: market + "/indAccInfoAction/save",
    method: "post",
    data: data || {}
  });
}

// 修改
export function update(data) {
  return request({
    url: market + "/indAccInfoAction/update",
    method: "post",
    data: data || {}
  });
}

// 删除
export function remove(params) {
  return request({
    url: market + "/indAccInfoAction/remove",
    method: "delete",
    data: params
  });
}

//  查看用户已经绑定卡
export function getCardByAccId(data) {
  return request({
    url: market + "/indAccInfoAction/getCardByAccId",
    method: "get",
    params: data || {}
  });
}

//  查看用户已经绑定车辆
export function getEvByAccId(data) {
  return request({
    url: market + "/indAccInfoAction/getEvByAccId",
    method: "get",
    params: data || {}
  });
}

// 客户管理绑定车辆
export function saveAccEvRela(data) {
  return request({
    url: market + "/indAccInfoAction/saveAccEvRela",
    method: "post",
    data: data || {}
  });
}
// 客户管理解绑车辆
export function updateAccEvRela(data) {
  return request({
    url: market + "/indAccInfoAction/updateAccEvRela",
    method: "post",
    data: data || {}
  });
}
